jQuery.extend(jQuery.browser,
{SafariMobile : navigator.userAgent.toLowerCase().match(/iP(hone|ad)/i) }
);
(function($) {
	$.format = function() {
		if (arguments.length == 0) return null;
		var str = arguments[0];
		for (var i = 1; i < arguments.length; i++) {
			var re = new RegExp('\\{' + (i - 1) + '\\}', 'gm');
			str = str.replace(re, arguments[i]);
		}
		return str.replace(/\{(\d+)\}/g, "");
	};
	$.toNumber = function(numstr) {
		if (/\d+/.test(numstr)) {
			numstr = /\d+/.exec(numstr);
		}else{
			return 0;
		}
		if (numstr == null || numstr == "") {
			numstr = "0";
		}
		return Math.ceil(Number(numstr));
	};
	$.toSortNumber = function(numstr, sortnum) {
		MaxSamePriceitemNUm = 10000;
		if (sortnum == null || sortnum == undefined || sortnum == "") {
			sortnum = parseInt(Math.random() * MaxSamePriceitemNUm);
		}
		return $.toNumber(numstr) * MaxSamePriceitemNUm + $.toNumber(sortnum);
	};
	$.toSortTime = function(timestr) {
		if (timestr == "" || timestr == null) {
			return "";
		}

		var reg = /(\d+).(\d+).(\d+).(\d+).(\d+).(\d+).*/;
		date_Y = timestr.replace(reg, "$1");
		date_M = timestr.replace(reg, "$2");
		date_D = timestr.replace(reg, "$3");
		date_h = timestr.replace(reg, "$4");
		date_m = timestr.replace(reg, "$5");
		date_s = timestr.replace(reg, "$6");

		var itemtime = new Date(date_Y, date_M - 1, date_D, date_h, date_m, date_s);
		return itemtime.getTime();
	};
	$.getNotNULL = function(o) {
		o = $.extend({
			input: "",
			nullvalue: "",
			delhtml: false
		},
		o || {});
		var reg = /<.[^>]*>/gi;
		if (o.input != "" && o.input != null && o.input != undefined) {
			return o.delhtml ? o.input.replace(reg, '') : o.input;
		} else if (o.nullvalue != "" && o.nullvalue != null && o.nullvalue != undefined) {
			return o.delhtml ? o.nullvalue.replace(reg, '') : o.nullvalue;
		} else {
			return "";
		}
	}
	URLEncode = function(c) {
		var o = '';
		var x = 0;
		c = c.toString();
		var r = /(^[a-zA-Z0-9_.]*)/;
		while (x < c.length) {
			var m = r.exec(c.substr(x));
			if (m != null && m.length > 1 && m[1] != '') {
				o += m[1];
				x += m[1].length;
			} else {
				if (c[x] == ' ') o += '+';
				else {
					var d = c.charCodeAt(x);
					var h = d.toString(16);
					o += '%' + (h.length < 2 ? '0': '') + h.toUpperCase();
				}
				x++;
			}
		}
		return o;
	};
	URLDecode = function(s) {
		var o = s;
		var binVal, t;
		var r = /(%[^%]{2})/;
		while ((m = r.exec(o)) != null && m.length > 1 && m[1] != '') {
			b = parseInt(m[1].substr(1), 16);
			t = String.fromCharCode(b);
			o = o.replace(m[1], t);
		}
		return o;
	};
	addBookmark = function(sTitle, sUrl) {
		if ($.browser.msie) {
			window.external.AddFavorite(sUrl, sTitle);
		}
		if ($.browser.mozilla) {
			window.sidebar.addPanel(sTitle, sUrl, "");
		}
	};
	GetTime = function(endtime) {
		var result = "";
		if (endtime == "") {
			return result;
		}
		var nowtime = new Date();
		var reg = /(\d+).(\d+).(\d+).(\d+).(\d+).(\d+).*/;
		date_Y = endtime.replace(reg, "$1");
		date_M = endtime.replace(reg, "$2");
		date_D = endtime.replace(reg, "$3");
		date_h = endtime.replace(reg, "$4");
		date_m = endtime.replace(reg, "$5");
		date_s = endtime.replace(reg, "$6");
		var itemtime = new Date(date_Y, date_M - 1, date_D, date_h, date_m, date_s);
		var lavetime = itemtime.getTime() - nowtime.getTime();
		if (lavetime < 0) {
			return search_interface["_leftno"];
		}
		var day = Math.floor(lavetime / (1000 * 60 * 60 * 24));
		var hour = Math.floor(lavetime / (1000 * 3600)) - (day * 24);
		var minute = Math.floor(lavetime / (1000 * 60)) - (day * 24 * 60) - (hour * 60);
		var second = Math.floor(lavetime / (1000)) - (day * 24 * 60 * 60) - (hour * 60 * 60) - (minute * 60);
		if (day != 0) {
			result += day + search_interface["_leftday"]
		}
		if (hour != 0) {
			result += hour + search_interface["_lefthours"]
		}
		if (minute != 0) {
			result += minute + search_interface["_leftminutes"]
		}
		if (second != 0) {
			result += second + search_interface["_leftseconds"]
		}
		return result;
	};
	GetAmazonPrice = function(itemid) {
		var itembox = $("#" + itemid);
		var amazon_price_url = itembox.find("#goto").attr("href");
		var pricebox1 = itembox.find(".item_price");
		var pricebox2 = itembox.find("#itemprice");
		//window.open("/WebService/search.php?type=getprice&url="+amazon_price_url);
		////////////////////////////////////////////////////////////
		$.ajax({
			type: "GET",
			url: "./WebService/search.php?type=getprice&url=" + amazon_price_url,
			beforeSend: function() {
				pricebox1.html("<img src=\"/template/images/sloading.gif\" />");
				pricebox2.html("<img src=\"/template/images/sloading.gif\" />");
			},
			success: function(data) {
				pricebox1.html(data + search_interface["_yen"]);
				pricebox2.html(data + search_interface["_yen"]);
				itembox.attr("data-sortprice", $.toSortNumber(data));
			}
		});
		////////////////////////////////////////////////////////////
	};
	initialize = function() {
		var t_lang = "zh-CN";
		switch (search_lang) {
		case "en":
			t_lang = "en";
			break;
		case "tw":
			t_lang = "zh-TW";
			break;
		case "cn":
			t_lang = "zh-CN";
			break;
		case "ja":
			t_lang = "ja";
			break;
		}
		//honyakufunc(".item_title");
		$(".item_title").each(function(key, value) {
			google.language.detect($(value).html(),
			function(result) {
				if (!result.error && result.language) {
					google.language.translate($(value).html(), result.language, t_lang,
					function(result) {
						if (result.translation) {
							$(value).html(result.translation);
						}
					});
				}
			});
		});
	};
	honyakufunc = function(obj) {
		$(obj).each(function(key, value) {
			google.language.detect($(value).html(),
			function(result) {
				if (!result.error && result.language) {
					google.language.translate($(value).html(), result.language, t_lang,
					function(result) {
						if (result.translation) {
							$(value).html(result.translation);
						}
					});
				}
			});
		});
	};
	RequestQuerystring = function(key, value, url) {
		if (arguments.length == 3) {
			pURL = url;
		} else {
			pURL = window.location.href;
		}
		var reg = new RegExp("([\?\&])(" + key + "=)([^\&]*)(\&?)", "i");
		if (reg.test(pURL)) {
			pURL1 = pURL.replace(reg, "$1$2" + value + "$4");
		} else {
			pURL1 = pURL + (pURL.indexOf("?") == -1 ? "?": "&") + key + "=" + value;
		}
		if (key == "Show") {
			return pURL1;
		}
		reg = new RegExp("([\?\&])(Show=)([^\&]*)(\&?)", "i");
		return pURL1.replace(reg, "$1$2" + $("#ShowType_B_S").val() + "$4");
	};
	openurl = function(key, sortby) {
		window.location.href = RequestQuerystring(key, sortby);
		//window.open(RequestQuerystring("s",sortby));
	};
	Fastsortby = function(sortby) {
		$("#Show_sortby").val(sortby);
		$.cookie("sortby", sortby, options);
		fastsortstr = sortby.split(",");
		//alert(fastsortstr[0]+"/"+fastsortstr[1]);
		var attr = "data-sortprice";
		var sort = fastsortstr[1];
		if (fastsortstr[0] == "price") {
			attr = "data-sortprice";
		} else if (fastsortstr[0] == "bids") {
			attr = "data-sortbids";
		} else if (fastsortstr[0] == "end") {
			attr = "data-sortend";
		}
		var itemsdiv = $(".result_" + $("#ShowType_B_S").val() + " div.items[" + attr + "]");
		itemsdiv.sortElements(function(a, b) {
			a = $.toNumber($(a).attr(attr));
			b = $.toNumber($(b).attr(attr));
			if (sort == "A") {
				return a > b ? 1 : -1;
			} else {
				return a > b ? -1 : 1;
			}
		});
		GetSorbyCookie();
		KanSea_pageindex("mypagelist", Childpagekey, 24, ChildpageNum);
	};
	/////////////////////////////////////////////
	default_Shop_hide = function() {
		if (search_type == "shopping") {
			$(".view-sort-cont-left span").each(function() {
				if ($(this).attr("id") != "shoponly" && $(this).attr("id") != "sortby") {
					$(this).remove();
				}
			});
		}
	}
	loadlang = function() {
		$("#menu_home").text(search_interface["_toppage"]);
		$("#menu_fjs").text(search_interface["_FJsearch"]);
		$(document)[0].title = search_interface["_FJsearch"];
		$("#menu_add").text(search_interface["_favorite"]);
		$("#menu_share").text(search_interface["_shareFJ"]);
		$("#menu_share").attr('href', 'mailto:?subject=' + search_interface["_mailsubject"] + '&body=http://www.fromjapan.co.jp/');
		$("#menu_mypage").text(search_interface["_mypage"]);
		//search
		$("#lang_search_price").text(search_interface["_price"]);
		$("#lang_search_yen").text(search_interface["_to"]);
		$("#lang_search_within").text(search_interface["_yen"]);
		//$("#lang_search_sort").text(search_interface["_sort"]);
		//button
		$("#lang_search_auction").text(search_interface["_auction"]);
		$("#lang_search_shopping").text(search_interface["_shopping"]);
		$("#lang_search_stone").html(search_interface["_stone"]);
		//$("#lang_search_new").html(search_interface["_new"]);
		$("#lang_search_buynow").html(search_interface["_sale"]);
		//top
		$("#lang_top_info_title").text(search_interface["_information_title"]);
		$("#lang_top_info").text(search_interface["_information"]);
		//search input
		$("#lang_search_defaultcategory").text(search_category["_default"]);
		//$("#search_area").val(search_category["_default"]);
		$("#input_title").text(search_interface["_button"] + ":");
		$("#search_submit").val(search_interface["_button"]);
		$("#special_link").text(search_interface["_advanced"]);
		$("input[name='q']").attr("title", search_interface["_FJsearch"]);
		$("#top_only").html(search_interface["_input_information"]);
		//sort by
		$("#sortby").text(search_interface["_search_sortby"] + ":");
		$("#ninki").text(search_interface["_search_Popular"]);
		$("#price").text(search_interface["_search_Price"]);
		$("#nogori").text(search_interface["_search_Remainingtime"]);
		$("#view").text(search_interface["_search_View"]);
		$("#irretu").append(search_interface["_search_row"]);
		$("#tateyoko").append(search_interface["_search_Line"]);
		$("#search_Feedback").text(search_interface["_search_satisfied"]);
		$("#checkhistory").text(search_interface["_Str_History"]);
		//page
		var siteimg = "";
		var img_sitesname = search_site.split(",");
		for (var img_key in img_sitesname) {
			if (siteimg != "") {
				siteimg += search_interface["_and"];
			}
			siteimg += "<img class=\"bg logos " + img_sitesname[img_key] + "\" src=\"/template/images/clear.gif\" alt=\"\"/>";
		}
		var itemnum_str = search_interface["_itemnum"].replace(/##type_siteimg#/g, search_interface["_" + search_type] + search_interface["_site"] + " " + siteimg);
		itemnum_str = itemnum_str.replace(/##keyword#/g, search_keyword);
		$("#search_all_items_num").html(itemnum_str);
		//##type_siteimg#搜索关键词##keyword#获得约 ##n
		//$("#search_all_items_num").append(" "+search_interface["_itemnum"]);
		//
		$("#lang_Availability").text(search_interface["_Input_advanced"]["_Availability"]);
		$("#lang_ImageFlag").text(search_interface["_Input_advanced"]["_ImageFlag"]);
		//input
		SetSelectLang("#lang_search_new", "#lang_search_item_status", search_interface["_new"]);
		SetSelectLang("#lang_search_area_title", "#lang_search_area", search_interface["_Select_Area"]);
		SetSelectLang("#lang_Gift_icon_title", "#lang_Gift_icon", search_interface["_Select_Gift_icon"]);
	};
	SetSelectLang = function(title_obj, select_obj, interface_lang) {
		$(title_obj).html(interface_lang["title"]);
		var select_option = "";
		if (interface_lang["default"] != undefined && interface_lang["default"] != null) {
			select_option = "<option value=\"\">" + interface_lang["default"] + "</option>";
		}
		for (var key in interface_lang) {
			if (key != "title" && key != "default") {
				select_option += "<option value=\"" + key + "\">" + interface_lang[key] + "</option>";
			}
		}
		$(select_obj).html(select_option);
	};
	SetCategory = function(CategoryList) {
		var selecthtml = "<option value=\"\">" + search_category["_default"] + "</option>";
		var resulthtml = "<option value=\"##CategoryKey#\" ###selected#>##Categoryname#</option>";
		var is_search_type = (search_type==$("input:radio:checked").val());
		var is_search_site = (search_site==$("#search_input_site").val());
		for (var key in CategoryList) {
			if (key != "_default") {
				addhtml = resulthtml.replace(/##CategoryKey#/g, key);
				
				if (key == search_category_value&&is_search_type&&is_search_site) {
					addhtml = addhtml.replace(/###selected#/g, "selected");
				} else {
					addhtml = addhtml.replace(/###selected#/g, "");
				}
				addhtml = addhtml.replace(/##Categoryname#/g, CategoryList[key]);
				selecthtml += addhtml;
			}
		}
		$("#search_category").html(selecthtml);
	};
	resetcategory = function() {
		//GetSites();
		nowselect_search_type = search_type;
		$("input:radio").each(function() {
			if ($(this).attr("checked") == true) {
				if ($(this).val() == "acution" || $(this).val() == "shopping") {
					nowselect_search_type = $(this).val();
				}
			}
		});
		$.getJSON(
			"./WebService/search.php?dom=JSON",
			{
				lang	: search_lang,
				site	: $("#search_input_site").val(),
				type	: nowselect_search_type,
				op		: "category",
				nocache	: Math.random() * 10000000000
			},
			function(json) {
				SetCategory(json);
			});
	};
	Sethotkey = function(Hotkeydata) {
		HotkeyHtmltemp = "<span>" + HotKeyStr + ":</span>";

		var copyThis = $($(".hot_keyword").clone(true)).hide().css({
			'position': 'absolute',
			'width': 'auto',
			'overflow': 'visible'

		});
		$(".hot_keyword").after(copyThis);

		var resulthtml = "<a href=\"?type=" + $("input:radio:checked").val() + "&s=price%2CA&p=1&n=100&Show=s&site=yahoo%2Cbidders&op=list&lang=" + search_lang + "&q=##hotkey#\" title=\"##hotkey#\" onclick=\"javascript:openloading();\">##hotkey#</a>";
		for (var key in Hotkeydata) {
			$(".hot_keyword").html(HotkeyHtmltemp);
			HotkeyHtmltemp += resulthtml.replace(/##hotkey#/g, Hotkeydata[key]);
			copyThis.html(HotkeyHtmltemp);
			if (copyThis.width() > $(".hot_keyword").width()) {
				break;
			} else {
				$(".hot_keyword").html(HotkeyHtmltemp);
			}
		}
	};
	reSetHotLink = function() {
		$(".hot_keyword a").each(function() {
			var hotlink = RequestQuerystring("type", $("input:radio:checked").val());
			hotlink = RequestQuerystring("site", $("#search_input_site").val(), hotlink);
			hotlink = RequestQuerystring("op", "list", hotlink);
			hotlink = RequestQuerystring("q", $(this).html(), hotlink);
			if (hotlink.indexOf("&s=") == -1) {
				hotlink += "&s=" + search_sort;
			}
			$(this).attr("href", hotlink.replace(/&amp;/g, "%26"));
		});
	};
	special = function() {
		$("#special_search").slideToggle("fast",
		function() {
			if ($(this).is(":hidden")) {
				$("#special_link").html(search_interface["_advanced"]);
			} else {
				$("#special_link").html(search_interface["_noadvanced"]);
				//$("#"+search_type).click();
			}
		});
	};
	checkkeyword = function() {
    if($.browser.SafariMobile){
        $("input[name='n']").val("20");
    }
		var keyword = $("input[name='q']").val();
		if (keyword == "" || keyword == null || keyword == searchstr) {
			return false;
		}else{
			openloading();
		}
		var sites = $("#search_input_site").val();
		if (sites == "" || sites == null || sites == ",") {
			$("#search_input_site").val("bidders");
			//return false;
		}
	};
	openloading = function(){
		$.floatbox({
			content: search_interface["_Str_Loading"]
		});
	};
	GetSites = function() {
		var thisobj_sites = $("#search_" + $("input:radio:checked").val() + " .search_checkbox_sites");
		//var thisobj_sites = $("input:radio:checked").parent().next().find(".search_checkbox_sites");
		var thisobj_expand = $("#expand_" + search_type);
		var sites = "",value, obj;
		$("input:checkbox[name='store']").attr("disabled", true);
		//$("input:checkbox[name='new']").attr("disabled",true);
		$("input:checkbox[name='buynow']").attr("disabled", true);
		$("select[name='item_status']").attr("disabled", true);
		$("select[name='loc_cd']").attr("disabled", true);
		$("select[name='gift_icon']").attr("disabled", true);
		$("#yahoo_select").attr("disabled", true);
		$("#rakuten_select").attr("disabled", true);
		//alert(thisobj_sites.find("input:checkbox:checked").size());
		thisobj_sites.find("input:checkbox").each(function() {
			value = $(this).val();
			if ($(this).attr("checked") == true) {
				if ($(this).attr("disabled") == false) {
					if (sites != "") {
						sites += ",";
					}
					sites += value;
					switch (value) {
					case "yahoo":
						$("input:checkbox[name='store']").attr("disabled", false);
						//$("input:checkbox[name='new']").attr("disabled",false);
						$("select[name='item_status']").attr("disabled", false);
						$("input:checkbox[name='buynow']").attr("disabled", false);
						$("select[name='loc_cd']").attr("disabled", false);
						$("select[name='gift_icon']").attr("disabled", false);
						$("#yahoo_select").attr("disabled", false);
						break;
					case "rakuten":
						$("#rakuten_select").attr("disabled", false);
						break;
					}
				}
			} else {
				if (value == "rakuten") {
					$("input[data-checkbox='expandimageFlag']").attr("checked", false);
					obj += ",input[data-checkbox='shoppingamazon']";
					obj += ",input[data-checkbox='shoppingkakaku']";
					obj += ",input[data-checkbox='shoppingbidders']";
					obj += ",input[data-checkbox='shoppingyahoo']";
				} else if (value == "yahoo") {
          if($("input:radio:checked").val()=="shopping"){
              $("input[data-checkbox='expandavailability']").attr("checked", false);
              obj += ",input[data-checkbox='shoppingrakuten']";
              obj += ",input[data-checkbox='shoppingamazon']";
              obj += ",input[data-checkbox='shoppingkakaku']";
              obj += ",input[data-checkbox='shoppingbidders']";
					}else if($("input:radio:checked").val()=="auction"){
              $("input:checkbox[name='store'],input:checkbox[name='buynow'],select[name='item_status'],select[name='loc_cd'],select[name='gift_icon']").attr("checked", false);
              obj = "input[data-checkbox='auctionbidders']";
					}
				}
				$(obj).attr("disabled", false);
			}
		});
		if (sites == "") {}
		$("#search_input_site").val(sites);
		resetcategory();
		reSetHotLink();
	};
	select_aucORshop = function(obj) {
		var parentDiv = $(obj).parent().parent();
		$(".search_type").removeClass("search_type_selected");
		parentDiv.addClass("search_type_selected");
		$(".search_checkbox_sites input:checkbox").attr("disabled", true);
		parentDiv.find(".search_checkbox_sites input:checkbox").attr({
			"disabled": false
		});
		parentDiv.find(".checkboxs").after($(".search_checkbox_common"));
		//$(".search_checkbox_common").appendTo(parentDiv.find(".search_checkbox"));
		//search_type = $(obj).attr("id");
		var newsearch_type = $(obj).attr("id");
		GetSites();
		var expandinput = $("#expand_" + newsearch_type);
		if (newsearch_type == "auction") {
			$("#expand_shopping").slideUp('fast');
		} else {
			$("#expand_auction").slideUp('fast');
		}
		//$(".search_checkbox_expand:visible").slideUp('fast');
		//$(".search_checkbox_expand:visible").hide()
		expandinput.slideDown('fast');
	};
	checkimgload = function(obj, maxwidth, maxheight) {
		$(obj).load(function() {
			$(this).css({
				width: "auto",
				height: "auto",
				"margin": "0px"
			});
			fiximagessize(this, maxwidth, maxheight);
		});
	};
	fiximagessize = function(obj, maxwidth, maxheight) {
		$(obj).each(function() {
			$(this).hide();
			$(this).css({
				width: "auto",
				height: "auto",
				"margin": "0px"
			});
			imgheight = $(this).height();
			imgwidth = $(this).width();
			fixwidth = imgwidth * maxheight / imgheight;
			if (imgheight >= maxheight) {
				$(this).css({
					height: maxheight,
					width: fixwidth
				});
				imgheight = maxheight;
				imgwidth = fixwidth;
			}
			fixheight = imgheight * maxwidth / imgwidth;
			if (imgwidth >= maxwidth) {
				$(this).css({
					width: maxwidth,
					height: fixheight
				});
				imgheight = fixheight;
				imgwidth = maxwidth;
			}
			marginlr = (maxwidth - imgwidth) / 2;
			margintb = (maxheight - imgheight) / 2;
			if ($(this).attr("id") == "itemimg") {
				marginlr = 0;
			}
			$(this).css({
				"margin-left": marginlr + "px",
				"margin-top": margintb + "px"
			});
			$(this).show();
		});
	};
	topdesign = function() {
		var autocompleteWidth = 470;
		if (Is_toppage == false) {
			$(".Condition").css({
				"width": "810px"
			}).prependTo("#search_right_top");
			$(".searcharea").prependTo("#search_content");
			$(".searcharea").css({
				width: "100%",
				margin: "0px"
			});
			$(".search_type:first").css({
				"margin-top": "20px"
			});
			$("#special_link").remove();
			$(".input_help,.hot_keyword").css({
				"margin-left": "210px",
				width: "770px"
			});
			$(".input_help").css({
				"text-align": "left",
				"width": "100%"
			});
			autocompleteWidth = 695;
			$("input[name='q']").css({
				"width": "695px"
			});
			$("#input_title").remove();
			$(".search_Feedback img").click(function() {
				if ($(".feedback").is(":hidden")) {
					$(".feedback").show();
				} else {
					$(".feedback").hide();
				}
				var feedsrc = $(".feedback").attr("src");
				feedsrc = feedsrc.replace("post", "");
				$(".feedback").attr("src", feedsrc);
			});
			if (search_keyword == " " || search_keyword == "") {
				$("#searchguide").html("<div class=\"searchguide\">" + search_interface["_Search_setumei"] + "</div>");
				$("#search_result").hide();
				//ie6
				$(".copyright").remove();
			}
			$(".setumei").remove();
		} else {
      $("#googleads").remove();
			$("#special_search").hide();
			if (search_type == "shopping") {
				$("#expand_auction").hide();
			} else {
				$("#expand_shopping").hide();
			}
		}
		$("body").show();
		keywordinput(autocompleteWidth);
	};
	keywordinput = function(autocompleteWidth) {
		$("input[name='q']").autocomplete("/autocomplete.php", {
			width: autocompleteWidth,
			max: 100,
			selectFirst: false,
			visible: false

		});
		$("input[name='q']").val((search_keyword == "") ? searchstr: search_keyword);
		if ($("input[name='q']").val() == searchstr) {
			$("input[name='q']").css({
				"color": "grey"
			})

		} else {
			$("input[name='q']").css({
				"color": "black"
			})

		}
		//keyword
		$("input[name='q']").click(function() {
			if ($(this).val() == searchstr) {
				$(this).val("");
			}
			$(this).css({
				"color": "black"
			});
		}).blur(function() {
			if ($(this).val() == "") {
				$(this).val(searchstr);
				$(this).css({
					"color": "grey"
				});
			} else {
				$(this).css({
					"color": "black"
				});
			}
		});
	};
})(jQuery);